<?php

/* @var $this \yii\web\View */
/* @var $content string */

use yii\helpers\Html;
use yii\bootstrap\NavBar;
use yii\bootstrap\Nav;
use frontend\modules\yii2\widgets\layouts\dockerdoc\assets\DockerDocAsset;
DockerDocAsset::register($this);
$isDockerActive = "active";
$this->beginPage();
echo "<!doctype html>";
echo "<html lang='zh-CN'>";
// head
echo Html::beginTag("head");
$this->registerMetaTag(["charset" => "utf-8"]);
$this->registerMetaTag(["http-equiv" => "X-UA-Compatible", "content" => "IE=edge"]);
$this->registerMetaTag(["name" => "viewport", "content" => "width=device-width, initial-scale=1"]);
$this->registerLinkTag(["rel" => "icon", "href" =>"https://www.yiichina.com/favicon.ico?v=1528501659"]);
$this->registerCsrfMetaTags();
echo Html::tag("title", Html::encode($this->title));
$this->head();
echo Html::endTag("head");
// body
echo "<body>";
$this->beginBody();

NavBar::begin([
    "brandImage" => '/images/logo.png',
    "containerOptions" => ["id" => "navbar"],
    "options" => ["class" => "navbar navbar-inverse navbar-fixed-top"]
]);
echo Nav::widget([
    "items" => [
        ["label" => "Home", "url" => "/", "linkOptions" => ["class" => Yii::$app->controller->id == "site" ? "active" : ""]],
        ["label" => "Bootstrap3", "url" => "/bootstrap3", "linkOptions" => ["class" => Yii::$app->controller->id == "bootstrap3" ? "active" : ""]],
        ["label" => "Docs", "url" => "/docs", "linkOptions" => ["class" => Yii::$app->controller->id == "docs" ? "active" : ""]],
        ["label" => "Docker Tools", "url" => "/docker", "linkOptions" => ["class" => Yii::$app->controller->id == "docker" ? "active" : ""]],
    ],
    "options" => ["class" => "nav navbar-nav navbar-left"],
]);
echo Nav::widget([
    "items" => [
        ["label" => "Contact", "url" => "/contact"],
    ],
    "options" => ["class" => "nav navbar-nav navbar-right"],
]);
NavBar::end();
